package com.celesea.framework.entity;

import javax.persistence.Column;
import javax.persistence.Id;
import java.io.Serializable;

/**
 * ${DESCRIPTION}
 *
 * @author JackYuan
 * @create 2017-10-25 14:13
 */
public abstract class BaseEntity implements Serializable {

    public static final String PK = "id";
    /**
     * 主键
     */
    @Id
    @Column(name = "`id`", columnDefinition = "主键", nullable = false)
    protected String id;
    /**
     * 租户Id
     */
    @Column(name = "`tenant_id`", columnDefinition = "租户Id", nullable = false, updatable = false)
    protected String tenantId;


    public BaseEntity() {
    }

    public String getTenantId() {
        return tenantId;
    }

    public void setTenantId(String tenantId) {
        this.tenantId = tenantId;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }
}
